package com.yuexinduo.education.fragment;

import android.content.Intent;
import android.view.View;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.yuexinduo.education.R;
import com.yuexinduo.baselibrary.base.BaseMvpFragment;
import com.yuexinduo.education.ui.BankCardActivity;
import com.yuexinduo.education.ui.ChargeStandardActivity;
import com.yuexinduo.education.ui.FamilyEducationActivity;
import com.yuexinduo.education.ui.FinanceOperationActivity;
import com.yuexinduo.education.ui.MemberInterestsActivity;
import com.yuexinduo.education.ui.MyCollectActivity;
import com.yuexinduo.education.ui.MyCourseActivity;
import com.yuexinduo.education.ui.MyDiscountsActivity;
import com.yuexinduo.education.ui.MyInviteActivity;
import com.yuexinduo.education.ui.MyLessonActivity;
import com.yuexinduo.education.ui.MyTeacherActivity;
import com.yuexinduo.education.ui.MyUpDataActivity;
import com.yuexinduo.education.ui.MyUpPassActivity;
import com.yuexinduo.education.ui.MyVideoActivity;
import com.yuexinduo.education.ui.OutMoneyTwoActivity;
import com.yuexinduo.education.ui.PayAccountActivity;

public class MineFragment extends BaseMvpFragment implements View.OnClickListener {
    private ImageView mineSet;
    private ImageView mineScan;
    private LinearLayout mineLinTeacher;
    private LinearLayout mineLinCourse;
    private LinearLayout mineLinInvite;
    private LinearLayout mineLinVideo;
    private LinearLayout mineLinLesson;
    private TextView mineCollect;
    private TextView mineDiscounts;
    private TextView mineData;
    private TextView mineUpPass;
    private TextView minePayAccount;
    private TextView mineOutMoney;
    private TextView mineBankCard;
    private TextView mineFinance;
    private TextView mineQuestion;
    private TextView mineAdd;
    private TextView mineExclamation;
    @Override
    public boolean isLazyLoad() {
        return false;
    }

    @Override
    protected int bindLayout() {
            return R.layout.fragment_mine;
    }

    @Override
    protected void initView() {


        mineSet = (ImageView) containerView.findViewById(R.id.mine_set);
        mineScan = (ImageView) containerView.findViewById(R.id.mine_scan);
        mineLinTeacher = (LinearLayout) containerView.findViewById(R.id.mine_lin_teacher);
        mineLinCourse = (LinearLayout) containerView.findViewById(R.id.mine_lin_course);
        mineLinInvite = (LinearLayout) containerView.findViewById(R.id.mine_lin_invite);
        mineLinVideo = (LinearLayout) containerView.findViewById(R.id.mine_lin_video);
        mineLinLesson = (LinearLayout) containerView.findViewById(R.id.mine_lin_lesson);
        mineDiscounts = (TextView) containerView.findViewById(R.id.mine_discounts);
        mineCollect = (TextView) containerView.findViewById(R.id.mine_collect);
        mineData = (TextView) containerView.findViewById(R.id.mine_data);
        mineUpPass = (TextView) containerView.findViewById(R.id.mine_up_pass);
        minePayAccount = (TextView) containerView.findViewById(R.id.mine_pay_account);
        mineOutMoney = (TextView) containerView.findViewById(R.id.mine_out_money);
        mineBankCard = (TextView) containerView.findViewById(R.id.mine_bank_card);
        mineFinance = (TextView) containerView.findViewById(R.id.mine_finance);
        mineQuestion = (TextView) containerView.findViewById(R.id.mine_question);
        mineAdd = (TextView) containerView.findViewById(R.id.mine_add);
        mineExclamation = (TextView) containerView.findViewById(R.id.mine_exclamation);


        mineScan.setOnClickListener(this);
        mineScan.setOnClickListener(this);
        mineLinCourse.setOnClickListener(this);
        mineLinTeacher.setOnClickListener(this);
        mineLinInvite.setOnClickListener(this);
        mineLinLesson.setOnClickListener(this);
        mineLinVideo.setOnClickListener(this);
        mineCollect.setOnClickListener(this);
        mineDiscounts.setOnClickListener(this);
        mineData.setOnClickListener(this);
        mineUpPass.setOnClickListener(this);
        minePayAccount.setOnClickListener(this);
        mineOutMoney.setOnClickListener(this);
        mineBankCard.setOnClickListener(this);
        mineFinance.setOnClickListener(this);
        mineQuestion.setOnClickListener(this);
        mineAdd.setOnClickListener(this);
        mineExclamation.setOnClickListener(this);
    }

    @Override
    protected void initData() {

    }

    @Override
    public void onClick(View v) {
        switch (v.getId()){
            case R.id.mine_scan:
                break;
            case R.id.mine_set:
                break;
            case R.id.mine_lin_course://我的课程
                startActivity(new Intent(getActivity(), MyCourseActivity.class));
                break;
            case R.id.mine_lin_invite://我的约课
                startActivity(new Intent(getActivity(), MyInviteActivity.class));
                break;
            case R.id.mine_lin_lesson://我的直播课
                startActivity(new Intent(getActivity(), MyLessonActivity.class));
                break;
            case R.id.mine_lin_video://我的视频课
                startActivity(new Intent(getActivity(), MyVideoActivity.class));
                break;
            case R.id.mine_lin_teacher://我的老师
                startActivity(new Intent(getActivity(), MyTeacherActivity.class));
                break;
            case R.id.mine_collect://我的收藏
                startActivity(new Intent(getActivity(), MyCollectActivity.class));
                break;
            case R.id.mine_discounts://我的优惠券
                startActivity(new Intent(getActivity(), MyDiscountsActivity.class));
                break;
            case R.id.mine_data://修改资料
                startActivity(new Intent(getActivity(), MyUpDataActivity.class));
                break;
            case R.id.mine_up_pass://修改密码
                startActivity(new Intent(getActivity(), MyUpPassActivity.class));
                break;
            case R.id.mine_pay_account://充值
                startActivity(new Intent(getActivity(), PayAccountActivity.class));
                break;
            case R.id.mine_out_money://提现
                startActivity(new Intent(getActivity(), OutMoneyTwoActivity.class));
                break;
            case R.id.mine_bank_card://银行卡
                startActivity(new Intent(getActivity(), BankCardActivity.class));
                break;
            case R.id.mine_finance://财务流水
                startActivity(new Intent(getActivity(), FinanceOperationActivity.class));
                break;
            case R.id.mine_add://请家教收费标准
                startActivity(new Intent(getActivity(), ChargeStandardActivity.class));
                break;
            case R.id.mine_question://请家教流程
                startActivity(new Intent(getActivity(), FamilyEducationActivity.class));
                break;
            case R.id.mine_exclamation://会员费及其权益
                startActivity(new Intent(getActivity(), MemberInterestsActivity.class));
                break;
        }
    }
}
